package cn.hackcloud.mutithread.mutilthread.stack;

public class Test {
	public static void main(String[] args) {
		MyStack object = new MyStack();
		P p = new P(object);
		C c = new C(object);
		C c1 = new C(object);
		C c2 = new C(object);
		C c3 = new C(object);
		C c4 = new C(object);
		ThreadA threadA = new ThreadA(p);
		ThreadB threadB = new ThreadB(c);
		ThreadB thread1 = new ThreadB(c1);
		ThreadB thread2 = new ThreadB(c2);
		ThreadB thread3 = new ThreadB(c3);
		ThreadB thread4 = new ThreadB(c4);
		threadA.start();
		threadB.start();
		thread1.start();
		thread2.start();
		thread3.start();
		thread4.start();

	}
}
